using Microsoft.AspNetCore.Http;
using UniversalAdmin.Application.DTOs;
using UniversalAdmin.Domain.Entities;

namespace UniversalAdmin.Application.Services;

public interface IDocumentService
{
    Task<DocumentDto> UploadDocumentAsync(Guid userId, IFormFile file, string? fileName = null);
    Task<PagedResultDto<DocumentDto>> GetAllDocumentsAsync(Guid userId, int page = 1, int pageSize = 10, string? keyword = null);
    Task<DocumentDto?> GetDocumentByIdAsync(Guid userId, Guid id);
    Task<bool> DeleteDocumentAsync(Guid userId, Guid id);
    Task<PagedResultDto<DocumentChunkDto>> GetDocumentChunksAsync(Guid userId, Guid documentId, int page = 1, int pageSize = 10);
    Task<bool> ReindexDocumentAsync(Guid userId, Guid documentId);
    Task<List<DocumentChunk>> ChunkDocumentAsync(Document document, int chunkSize = 1000, int overlap = 200);
}